package fs.tileMap.view.tile {
	import flash.display.DisplayObjectContainer;
	import flash.display.Sprite;
	
	/**
	 * ...
	 * @author flyingSnow
	 */
	public class AbstractTile extends Sprite implements ITile {
		private var _code:int=-1;
		public function AbstractTile() {
			
		}
		
		/* INTERFACE fs.tileMap.view.tile.ITile */
		
		final public function showTile(code:int):void {
			if (_code != code) {
				_code = code;
				render(code);
			}			
		}
		
		protected function render(code:int):void {}
		
		public function getTileWidth():uint {
			return 10;
		}
		
		public function getTileHeight():uint {
			return 10;
		}
		
		public function get code():int {
			return _code;
		}
		
		
	}

}